import java.util.Scanner;

public class Answer2 {
    //跳台阶
    //https://www.nowcoder.com/practice/bfb2a2b3cdbd4bd6bba0d4dca69aa3f0?tpId=230&tqId=39749&ru=/exam/oj
    public static void main01(String[] args) {
        Scanner in = new Scanner(System.in);
        int n = in.nextInt();
        int[] dp=new int[n+1];
        dp[0]=1;
        dp[1]=1;
        for(int i=2;i<=n;i++){
            dp[i]=dp[i-1]+dp[i-2];
        }
        System.out.println(dp[n]);

    }

    // 空间优化后
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int n = in.nextInt();
        int a = 1, b = 1, c = 0;
        for (int i = 2; i <= n; i++) {
            c = a + b;
            a = b;
            b = c;
        }

        if (n == 1 || n == 0) {
            System.out.println(n);
        } else {
            System.out.println(c);
        }
    }
}
